#include <iostream>

using namespace std;

int * func_1(int num)
{
    // 创建空间
    int * num_ptr = new int(1000);
    return num_ptr;
}

int main(int argc, char const *argv[])
{
    int * num_ptr = func_1(10);

    cout << *num_ptr << endl;

    *num_ptr = 100;

    cout << *num_ptr << endl;

    //释放空间
    delete num_ptr;
    
    return 0;
}
